/**
 * 
 */
package mapmaker.utils;

import mapmaker.pose.Position;

/**
 * @author Acid Flow
 *
 */
public class Utilities {

	
	public static int nextPowerOf2(int x){
		int ret = 1;
		while(ret < x){
			ret <<= 1;
		}
		return ret;
	}
	
	public static double norm(Position p, Position q) {
		return Math.sqrt(Math.pow(p.getX() - q.getX(), 2) + 
					 	 Math.pow(p.getY() - q.getY(), 2)); 
	}
}
